package com.vincent.template.repository;

import com.vincent.template.commons.base.BaseJpaRepository;
import com.vincent.template.domain.SysBindRoleAuthPo;

import java.util.Collection;
import java.util.List;

/**
 * @author Vincent Wang
 * @date 2020/12/30 11:18
 */
public interface SysBindRoleAuthRepository extends BaseJpaRepository<SysBindRoleAuthPo, Long> {
    List<SysBindRoleAuthPo> findByRoleIdIn(Collection<Long> roleIds);
    List<SysBindRoleAuthPo> findByAuthId(Long authId);
    int deleteByRoleId(Long roleId);
    List<SysBindRoleAuthPo> findByRoleIdAndAuthIdIn(Long roleId, Collection<Long> authIds);
}
